import configparser
config =configparser.ConfigParser()

config['PATH']={}
config['PATH']['PATH']='C:/Program Files (x86)/Google/Chrome/Application/chromedriver.exe'

config['URL']={}
config['URL']['baiud_url']='https://www.baidu.com'
config['URL']['XXDHT_URL']='http://52.80.159.11:8204/login'

config['DATABADE']={}
config['DATABADE']['host']='database-url'
config['DATABADE']['port']='database-port'
config['DATABADE']['username']='database-username'
config['DATABADE']['passworld']='database-passworld'

with open('congfigfile.ini','w') as fp:
    config.write(fp)